<% unless @user.new_record? %>
  <% block_form :width=>550 do %>
	  <div style="padding:10px">
		  <%= t('user.created_at') %>: <%= I18n.l(@user.created_at, :format=>:long) %><br/>
		  <%= t('user.activated_at') %>: <%= I18n.l(@user.activated_at, :format=>:long) unless @user.activated_at.nil? %><br/>
		  <%= t('user.last_logged_at') %>: <%= I18n.l(@user.last_logged_at, :format=>:long) unless @user.last_logged_at.nil? %><br/>
	  </div>
	<% end %>
<% end %>

<%= form.error_messages %>

<%= form.label :name %><br/>
<%= form.text_field :name, :class=>"title" %><br/>

<%= form.label :email %><br/>
<%= form.text_field :email, :class=>'text' %><br/>

<%= form.label :password %><br/>
<%= form.password_field :password, :class=>'text' %><br/>

<%= form.label :password_confirmation %><br/>
<%= form.password_field :password_confirmation, :class=>'text' %><br/>

<%= form.label :avatar_data %> <small>(150x150)</small><br/>
<%= form.file_field :avatar_data %><br/>

<% unless @user.new_record? %>
  <p>
    <%= t('manage.user_actions') %>
    <% @user.aasm_events_for_current_state.each do |event| %>
      <%= link_to event, "/manage/users/#{@user.id}/#{event}", :method=>:post %>
    <% end %>
  </p>
<% end %>
